Skip to content

Conversation

@OlegoO
Copy link
Contributor

@OlegoO OlegoO commented Nov 17, 2025

Description

feat: Improved performance in document processing.
feat: Added a new configuration setting Content:StatisticEnabled (by default false) to allow enabling/disabling content statistics. Set to true to display page statistics, but it can lead to performance degradation for a huge number of files.
feat: Improve Content UX.

image

References

QA-test:

Jira-link:

https://virtocommerce.atlassian.net/browse/VCST-4291

Artifact URL:

https://vc3prerelease.blob.core.windows.net/packages/VirtoCommerce.Content_3.832.0-pr-204-869a.zip


Note

Parallelizes content indexing, adds cached change enumeration, introduces Content:StatisticEnabled to gate stats, updates stats API behavior, and refreshes UI tiles with conditional counters and new styles.

  • Backend:
    • Search/Indexing:
      • Parallelizes GetDocumentsAsync in ContentIndexDocumentBuilder using Parallel.ForEachAsync and ConcurrentBag.
      • Caches file enumerations in ContentIndexDocumentChangesProvider via IPlatformMemoryCache (per store/content type) with cache invalidation and 3h expiration; updates constructor deps.
    • Configuration: Adds configuration.IsContentStatisticEnabled() for new Content:StatisticEnabled setting.
    • API: GET ~/api/content/{storeId}/stats now validates store, always returns ActiveThemeName, and conditionally fetches counts; defaults counts to -1 when statistics disabled.
  • Frontend (Admin UI):
    • Redesigns Content main tiles into icon widgets; adds click-to-open store; simplifies active theme tile.
    • Hides counters when statistics are disabled (>= 0 checks) across main blade and storeCMSWidget.
    • Adds CSS for new content widgets (vc-content-widget*).

Written by Cursor Bugbot for commit 6506034. This will update automatically on new commits. Configure here.

feat: Improved performance in document processing.
Copy link
Contributor

@vc-ci vc-ci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test Suite: Test Suites/Modules/module_Assets
Tests: 13
Failures: 0
Errors: 0
Time: 7.588
Timestamp: 17-11-2025T12:09:50

@sonarqubecloud
Copy link

Copy link
Contributor

@vc-ci vc-ci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test Suite: Test Suites/Modules/module_Assets
Tests: 13
Failures: 0
Errors: 0
Time: 8.117
Timestamp: 17-11-2025T16:42:42

Copy link
Contributor

@vc-ci vc-ci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test Suite: Test Suites/Modules/module_Assets
Tests: 13
Failures: 0
Errors: 0
Time: 7.75
Timestamp: 18-11-2025T07:10:04

@OlegoO OlegoO merged commit 3044703 into dev Nov 24, 2025
2 of 3 checks passed
@OlegoO OlegoO deleted the fix/VCST-4291 branch November 24, 2025 07:14
_log.LogError(e, "Cannot create document for ID '{DocumentId}'", documentId);
}
}
});
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Unused cancellation token in parallel loop

The cancellationToken parameter in the Parallel.ForEachAsync lambda is provided but never used in the async operations inside the loop. The GetFile and CreateDocument methods don't receive the token, preventing proper cancellation propagation. This means the parallel operations cannot be cancelled even when a cancellation is requested.

Fix in Cursor Fix in Web

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants